From c41296336a0fa1352e3f8ee87ecd78b1a1a8d252 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Mon, 22 Jan 2007 15:19:53 +0000 Subject: [PATCH] =?utf8?q?Bug=20399314=20=E2=80=93=20Add=20G=5FGNUC=5FWARN?= =?utf8?q?=5FUNUSED=5FRESULT=20to=20gtk=5Fstyle=5Fattach?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit 2007-01-22 Chris Wilson Bug 399314 – Add G_GNUC_WARN_UNUSED_RESULT to gtk_style_attach * gtk/gtkstyle.h: Cause gcc to issue a warning if the style returned from gtk_style_attach is not used. Failure to update widget->style causes some very difficult to identify bugs, eg Bug 353498 – crash in Terminal: changing icon theme. svn path=/trunk/; revision=17199 --- ChangeLog | 10 ++++++++++ gtk/gtkstyle.h | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 20276fb04a..4f6a87f70a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2007-01-22 Chris Wilson + + Bug 399314 – Add G_GNUC_WARN_UNUSED_RESULT to gtk_style_attach + + * gtk/gtkstyle.h: + Cause gcc to issue a warning if the style returned from + gtk_style_attach is not used. Failure to update + widget->style causes some very difficult to reproduce bugs, + eg Bug 353498 – crash in Terminal: changing icon theme. + 2007-01-19 Michael Emmel * gdk/directfb/gdkevents-directfb.c: added fixes for window diff --git a/gtk/gtkstyle.h b/gtk/gtkstyle.h index e4f71c6f8d..0e758f1eac 100644 --- a/gtk/gtkstyle.h +++ b/gtk/gtkstyle.h @@ -427,7 +427,7 @@ GType gtk_style_get_type (void) G_GNUC_CONST; GtkStyle* gtk_style_new (void); GtkStyle* gtk_style_copy (GtkStyle *style); GtkStyle* gtk_style_attach (GtkStyle *style, - GdkWindow *window); + GdkWindow *window) G_GNUC_WARN_UNUSED_RESULT; void gtk_style_detach (GtkStyle *style); #ifndef GTK_DISABLE_DEPRECATED -- 2.30.2